<% let count = 0; %><table class="table table-striped">
    <thead>
        <tr>
            <% if (log_type === 'errors' || log_type === 'stream_errors') {
            count = 5; %>
            <th>Date</th>
            <th>Time</th>
            <th>Severity</th>
            <th>Number</th>
            <th>Message</th>
            <% } else if (log_type === 'accesses') {
            count = 9; %>
            <th>Time</th>
            <th>Remote IP</th>
            <th>Username</th>
            <th>Status</th>
            <th>Size</th>
            <th>Referer</th>
            <th>User Agent</th>
            <th>Forwarded For</th>
            <th>Request Line</th>
            <% } else {
            count = 6; %>
            <th>Time</th>
            <th>Remote IP</th>
            <th>Status</th>
            <th>Bytes Sent</th>
            <th>Bytes Received</th>
            <th>Session Time</th>
            <% } %>
        </tr>
        <tr class="filter">
            <% if (log_type === 'errors' || log_type === 'stream_errors') { %>
            <td><input type="text" value="<%= model.escape('date') %>" name="date" /></td>
            <td><input type="text" value="<%= model.escape('time') %>" name="time" /></td>
            <td><input type="text" value="<%= model.escape('severity') %>" name="severity" /></td>
            <td><input type="text" value="<%= model.escape('number') %>" name="number" /></td>
            <td><input type="text" value="<%= model.escape('message') %>" name="message" /></td>
            <% } else if (log_type === 'accesses') { %>
            <td><input type="text" value="<%= model.escape('time') %>" name="time" /></td>
            <td><input type="text" value="<%= model.escape('remote_ip') %>" name="remote_ip" /></td>
            <td><input type="text" value="<%= model.escape('username') %>" name="username" /></td>
            <td><input type="text" value="<%= model.escape('status') %>" name="status" /></td>
            <td><input type="text" value="<%= model.escape('size') %>" name="size" /></td>
            <td><input type="text" value="<%= model.escape('http_referer') %>" name="http_referer" /></td>
            <td><input type="text" value="<%= model.escape('user_agent') %>" name="user_agent" /></td>
            <td><input type="text" value="<%= model.escape('forwarded_for') %>" name="forwarded_for" /></td>
            <td><input type="text" value="<%= model.escape('request_line') %>" name="request_line" /></td>
            <% } else { %>
            <td><input type="text" value="<%= model.escape('time') %>" name="time" /></td>
            <td><input type="text" value="<%= model.escape('remote_ip') %>" name="remote_ip" /></td>
            <td><input type="text" value="<%= model.escape('status') %>" name="status" /></td>
            <td><input type="text" value="<%= model.escape('bytes_sent') %>" name="bytes_sent" /></td>
            <td><input type="text" value="<%= model.escape('bytes_received') %>" name="bytes_received" /></td>
            <td><input type="text" value="<%= model.escape('session_time') %>" name="session_time" /></td>
            <% } %>
        </tr>
    </thead>
    <tbody>
    </tbody>
    <tfoot>
        <tr>
            <td>
                <button class="btn btn-primary" id="paging_back"><i class="fa fa-backward" aria-hidden="true"></i></button>
                <button class="btn btn-primary" id="paging_forward"><i class="fa fa-forward " aria-hidden="true"></i></button>
            </td>
            <td colspan="3">
                Entries per page:
                <input type="range" list="tickmarks" min="5" max="1000" step="5" id="entrycount" value="100" />
                <datalist id="tickmarks">
                    <option value="5" label="5">
                    <option value="100" label="100">
                    <option value="200" label="200">
                    <option value="300">
                    <option value="400">
                    <option value="500" label="500">
                    <option value="600">
                    <option value="700">
                    <option value="800">
                    <option value="900">
                    <option value="1000" label="1000">
                </datalist>
            </td>
            <td colspan="<%= count - 3 %>"></td>
        </tr>
    </tfoot>
</table>
